--{'quartz:quartz_crystal_piece', 'jump'}

local armor_material = {
   gravity = 'epic:float_crystal',
   healing = 'epic:bloodstone',
   water = 'ocean:prismarine_crystals',
   fire = 'epic:huntite',
   speed = 'epic:garnet',
}

for name, mat in pairs(armor_material) do
   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 5,
         ['mobs:leather'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:helmet_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 8,
         ['mobs:leather'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:chestplate_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 7,
         ['mobs:leather'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:leggings_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 4,
         ['mobs:leather'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:boots_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 5,
         ['group:fabric'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:helmet_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 8,
         ['group:fabric'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:chestplate_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 7,
         ['group:fabric'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:leggings_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 4,
         ['group:fabric'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:boots_'..name,
   })

--Adding Enchantments to existing armor
   stations.dual_register_recipe('crystal_w', {
      input = {
         ['3d_armor:helmet_diamond'] = 1,
         ['default:diamond'] = 1,
         ['group:fabric'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:helmet_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['3d_armor:chestplate_diamond'] = 1,
         ['default:diamond'] = 1,
         ['group:fabric'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:chestplate_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['3d_armor:leggings_diamond'] = 1,
         ['default:diamond'] = 1,
         ['group:fabric'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:leggings_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['3d_armor:boots_diamond'] = 1,
         ['default:diamond'] = 1,
         ['group:fabric'] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:boots_'..name,
   })

--Enchanted Repairs
   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 1,
         ['epic:helmet_'..name] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:helmet_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 1,
         ['epic:chestplate_'..name] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:chestplate_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 1,
         ['epic:leggings_'..name] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:leggings_'..name,
   })

   stations.dual_register_recipe('crystal_w', {
      input = {
         ['default:diamond'] = 1,
         ['epic:boots_'..name] = 1,
         ['stations:chitin'] = 1,
         [mat] = 1,
      },
      output = 'epic:boots_'..name,
   })

end

stations.dual_register_recipe('crystal_w', {
   input = {
      ['default:diamond'] = 5,
      ['mobs:leather'] = 1,
      ['stations:chitin'] = 1,
   },
   output = '3d_armor:helmet_diamond',
})

stations.dual_register_recipe('crystal_w', {
   input = {
      ['default:diamond'] = 8,
      ['mobs:leather'] = 1,
      ['stations:chitin'] = 1,
   },
   output = '3d_armor:chestplate_diamond',
})

stations.dual_register_recipe('crystal_w', {
   input = {
      ['default:diamond'] = 7,
      ['mobs:leather'] = 1,
      ['stations:chitin'] = 1,
   },
   output = '3d_armor:leggings_diamond',
})

stations.dual_register_recipe('crystal_w', {
   input = {
      ['default:diamond'] = 4,
      ['mobs:leather'] = 1,
      ['stations:chitin'] = 1,
   },
   output = '3d_armor:boots_diamond',
})

stations.dual_register_recipe('crystal_w', {
   input = {
      ['default:diamond'] = 7,
      ['stations:chitin'] = 1,
   },
   output = 'shields:shield_diamond',
})

stations.dual_register_recipe('crystal_w', {
   input = {
      ['default:diamond'] = 5,
      ['group:fabric'] = 1,
      ['stations:chitin'] = 1,
   },
   output = '3d_armor:helmet_diamond',
})

stations.dual_register_recipe('crystal_w', {
   input = {
      ['default:diamond'] = 8,
      ['group:fabric'] = 1,
      ['stations:chitin'] = 1,
   },
   output = '3d_armor:chestplate_diamond',
})

stations.dual_register_recipe('crystal_w', {
   input = {
      ['default:diamond'] = 7,
      ['group:fabric'] = 1,
      ['stations:chitin'] = 1,
   },
   output = '3d_armor:leggings_diamond',
})

stations.dual_register_recipe('crystal_w', {
   input = {
      ['default:diamond'] = 4,
      ['group:fabric'] = 1,
      ['stations:chitin'] = 1,
   },
   output = '3d_armor:boots_diamond',
})
